package com.phil.tuangou.main.activtiy;

import java.util.List;

import com.phi.tuangou.bean.CityBean;

public class AsynRequestThread {
	ITuanGou tuangou;

	public AsynRequestThread(ITuanGou tuangou) {
		this.tuangou = tuangou;
	}

	public void requestCitys(final RequestListener listener) {
		new Thread() {
			@Override
			public void run() {
				try {
					System.out.println("come in ");
					List<CityBean> list = tuangou.getCitys();
					
					listener.onSuccuss(list);
				} catch (Exception e) {
					listener.onExcepiton();
				}

			}
		}.start();
	}
}
